

<template>
  <div class="design" style="background: #fff">
    <div>
      <van-tabs v-model="active">
        <!-- 公司介绍tab -->
        <van-tab title="设计团队">
          <!--设计团队模块 -->

          <div
            ref="bigox"
            style="width: 100%; margin: 1rem 0; background: white"
          >
            <div
              class="evaluate"
              v-for="(vlu, index) in designlist"
              :key="index"
              @click="
                $router.push({ path: '/renovation/designerdeta/' + vlu.id })
              "
            >
              <!-- 用户信息 -->
              <div class="evaluateone">
                <div class="nextevaluateone">
                  <div style="margin-left: 0.6rem">
                    <img
                      :src="vlu.icon"
                      alt=""
                      style="height: 2.5rem; width: 2.5rem; border-radius: 50%"
                    />
                  </div>
                  <div style="">
                    <p
                      style="
                        margin-top: 0;
                        font-size: 0.85rem;
                        font-weight: 550;
                        letter-spacing: 3px;
                        margin-left: 1rem;
                      "
                    >
                      {{ vlu.name }}
                    </p>
                    <p
                      style="
                        font-size: 0.85rem;
                        margin-top: 0.1rem;
                        margin-left: 1rem;
                        width: 90%;
                      "
                    >
                      <span>{{ vlu.title }}</span>
                      <span> 作品 {{ vlu.introduce }}</span>
                    </p>
                  </div>
                  <div
                    style="
                      color: #5d5c61;
                      text-align: right;
                      padding-right: 0.8rem;
                      width: 40%;
                    "
                  >
                    <p class="experi">
                      <span>{{ vlu.experience }}年经验</span>
                    </p>
                  </div>
                </div>
              </div>

              <div class="showimg" style="">
                <div style="">
                  <img :src="vlu.icon" alt="" style="" />
                </div>
              </div>
              <div
                style="
                  border-top: 1px solid #e3e3e3;
                  width: 80%;
                  margin: auto;
                  padding: 0.5rem 0;
                "
              ></div>
            </div>
          </div>
        </van-tab>
        <!-- 资质荣誉tab -->
        <van-tab title="施工团队">
          <div
            ref="bigox"
            style="width: 100%; margin: 1rem 0; background: white"
          >
            <div
              class="evaluate"
              v-for="(vlu, index) in constrlist"
              :key="index"
              @click="
                $router.push({ path: '/renovation/tructionteam/' + vlu.id })
              "
            >
              <!-- 用户信息 -->
              <div class="evaluateone">
                <div class="nextevaluateone">
                  <div style="margin-left: 0.6rem">
                    <img
                      :src="vlu.icon"
                      alt=""
                      style="height: 2.5rem; width: 2.5rem; border-radius: 50%"
                    />
                  </div>
                  <div style="width: 65%">
                    <p
                      style="
                        margin-top: 0;
                        font-size: 0.85rem;
                        font-weight: 550;
                        letter-spacing: 3px;
                        margin-left: 1rem;
                      "
                    >
                      {{ vlu.name }}
                    </p>
                    <p
                      style="
                        font-size: 0.85rem;

                        margin-left: 1rem;
                      "
                    >
                      <span>{{ vlu.title }}</span>
                    </p>
                  </div>
                  <div
                    style="
                      color: #5d5c61;
                      text-align: right;
                      padding-right: 0.8rem;
                    "
                  >
                    <p class="experi">
                      <span>{{ vlu.experience }}年经验</span>
                    </p>
                  </div>
                </div>
              </div>
              <div
                style="
                  border-top: 1px solid #e3e3e3;
                  width: 80%;
                  margin: auto;
                  padding: 0.5rem 0;
                "
              ></div>
            </div>
          </div>
        </van-tab>
      </van-tabs>
    </div>
  </div>
</template>

<script>
import { design, exper } from '@/api/api';
import scrollFixed from '@/mixin/scroll-fixed';
import { getLocalStorage } from '@/utils/local-storage';
import decorationlist from '@/components/decorationlist';
import logo_default from '@/assets/images/logo.jpg';
import { Toast, Row, Col, Tab, Tabs } from 'vant';

export default {
  name: 'design',

  data() {
    return {
      designlist: '',
      constrlist: '',
    };
  },

  created() {
    this.initViews();
  },

  watch: {},
  methods: {
    // 保护
    initViews() {
      design({}).then((res) => {
        this.designlist = res.data.data.list;
        console.log(this.designlist);
      });
      exper({}).then((res) => {
        this.constrlist = res.data.data.list;
        console.log(this.constrlist);
      });
    },
  },

  components: {
    [Toast.name]: Toast,
    [Row.name]: Row,
    [Col.name]: Col,
    [Tab.name]: Tab,
    [Tabs.name]: Tabs,
  },
};
</script>

<style lang="scss" scoped>
// 设计团队模块

// 用户评价
.evaluate {
  .evaluateone {
    .nextevaluateone {
      padding: 0.5rem 0;
      display: flex;
      width: 100%;
      p {
        margin: 0.2rem 0;
      }
    }
  }
  .evaluatetwo {
    height: auto;
    width: 70%;
    padding-bottom: 1.1rem;
    // border-bottom: 1px solid rgba(0, 0, 0, 0.2);
    margin: auto;
    div:nth-child(1) {
      display: -webkit-box;
      overflow: hidden;
      -webkit-box-orient: vertical;
      -webkit-line-clamp: (2);
    }
  }
}
.showimg {
  width: 80%;
  margin: auto;
  display: flex;
  height: auto;
  padding: 0.5rem 0;
  justify-content: space-between;
  flex-direction: row;
  flex-wrap: wrap;
  // align-items: center;
  img {
    height: 5.5rem;
    width: 5.5rem;
    border-radius: 10px;
  }
  // img:nth-child(2),
  // img:nth-child(3) {
  //   margin-left: 0.2rem;
  // }
}
.evaluatepan {
  height: auto;
  width: 70%;
  padding-bottom: 1.1rem;
  // border-bottom: 1px solid rgba(0, 0, 0, 0.2);
  margin: auto;
  div:nth-child(1) {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: (2);
  }
  div:nth-child(2) {
    display: flex;
    height: auto;
    padding: 0.5rem 0;
    justify-content: space-between;
    flex-direction: row;
    flex-wrap: wrap;
    // align-items: center;
    img {
      height: 6.5rem;
      width: 6.5rem;
      border-radius: 10px;
    }
    // img:nth-child(2),
    // img:nth-child(3) {
    //   margin-left: 0.2rem;
    // }
  }
}
.experi {
  display: inline-block;
  padding: 0.1rem;
  font-size: 11px;
  border-radius: 10%;
  border: 1px solid #1c856a;
  color: #1c856a;
}
</style>
